package com.yb0os1.mapper;

import com.yb0os1.entity.DishFlavors;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface DishFlavorMapper {
    void insert(List<DishFlavors> flavors);

    void update(List<DishFlavors> flavors);

    @Select("select * from dish_flavor where dish_id=#{id}")
    List<DishFlavors> selectByDishId(Long id);

    @Delete("delete from dish_flavor where dish_id=#{id}")
    void deleteByDishId(Long id);
}
